package com.demo.oauth.server.service;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.demo.oauth.server.mapper.AuthenticationCodeMapper;
import com.demo.oauth.server.model.AuthenticationCode;

@Service
public class AuthenticationCodeService {

	@Autowired
	private AuthenticationCodeMapper authenticationCodeMapper;

	public int insert(AuthenticationCode code) {
		return authenticationCodeMapper.insert(code);
	}

	public int remove(String code) {
		return authenticationCodeMapper.deleteById(code);
	}

}
